package com.example.demo.service;

import com.example.demo.dao.StockMangeMapper;
import com.example.demo.entity.CommonResult;
import com.example.demo.entity.drugs;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StockMangeService implements StockMangeimpl{
    @Autowired
    StockMangeMapper stockMangeMapper;

    @Override
    public CommonResult selectStock(String drug_id, Integer amount) {
        List<drugs> drugs = stockMangeMapper.selectgoodsStock(drug_id, amount);
        return new CommonResult(200,"库存查询信息",drugs);
    }
}
